Keycloak REST Services 1.5.0-Final

Path: / admin / realms / {realm} / clients / {id} / certificates / {attr} / generate-and-download

Generate new keypair and certificate and downloads private key into specified keystore format. Only generated certificate is saved in Keycloak DB, but private key is not.

Path parameters:
realm - realm name (not id!)
id - id of client (not client-id)
attr -

Resource Methods
Method Summary
NameDescription
POST /admin/realms/{realm}/clients/{id}/certificates/{attr}/generate-and-downloadGenerate new keypair and certificate and downloads private key into specified keystore format.

Method Detail

POST /admin/realms/{realm}/clients/{id}/certificates/{attr}/generate-and-download

Generate new keypair and certificate and downloads private key into specified keystore format. Only generated certificate is saved in Keycloak DB, but private key is not.

HTTP Example:
POST /admin/realms/{realm}/clients/{id}/certificates/{attr}/generate-and-download
API Example:

ClientAttributeCertificateResource.generateAndGetKeystore({'realm': /* name realm name (not id!) */,
  'id': /* id id of client (not client-id) */,
  'attr': /* attributePrefix */,
  '$entity': /* config */});

Input:
KeyStoreConfig
Output:
byte[] -
Produces:
application/octet-stream
Consumes:
application/json

Keycloak REST Services 1.5.0-Final